<!-- MultimodalAnalysisAnalyse.vue -->
<template>
  <div class="analysis-workbench">
    <div class="workbench-header">
      <h1 class="workbench-title">电磁数据智能分析工作台</h1>
      <div class="workbench-controls">
        <el-select v-model="dataSource" size="small" placeholder="数据源选择">
          <el-option
              v-for="item in dataSources"
              :key="item.value"
              :label="item.label"
              :value="item.value"
          />
        </el-select>
        <el-button type="primary" size="small" @click="runAnalysis">
          <el-icon><MagicStick /></el-icon>
          执行分析
        </el-button>
      </div>
    </div>

    <div class="analysis-dashboard">
      <HierarchicalAnalysis />
      <ModelRepository />
    </div>

    <div class="workbench-footer">
      <div class="status-indicator">
        <el-icon><CircleCheckFilled /></el-icon>
        <span>分析状态: <span class="status-active">运行中</span></span>
      </div>
      <div class="execution-info">
        当前分析: <span class="highlight">雷达信号特征提取</span> |
        使用模型: <span class="highlight">时频分析</span> |
        耗时: <span class="highlight">42ms</span>
      </div>
    </div>
  </div>
</template>

<script setup>
import { ref } from 'vue'
import { MagicStick, CircleCheckFilled } from '@element-plus/icons-vue'
import HierarchicalAnalysis from './analyse/HierarchicalAnalysis.vue'
import ModelRepository from './analyse/ModelRepository.vue'
import {ElButton, ElIcon, ElOption, ElSelect} from "element-plus";

const dataSource = ref('radar')
const dataSources = ref([
  { value: 'radar', label: '雷达信号数据' },
  { value: 'spectrum', label: '频谱监测数据' },
  { value: 'satellite', label: '卫星遥感数据' }
])

const runAnalysis = () => {
  console.log('执行分析...')
}
</script>

<style scoped>
.analysis-workbench {
  display: flex;
  flex-direction: column;
  height: 100vh;
  width: 95vw;
  background: linear-gradient(135deg, #0c1124 0%, #1a2444 100%);
  font-family: 'Segoe UI', 'Microsoft YaHei', sans-serif;
  color: #e4f0ff;
  overflow: hidden;
}

.workbench-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2vh;
  padding-bottom: 1.5vh;
  border-bottom: 1px solid rgba(75, 130, 230, 0.3);
}

.workbench-title {
  font-size: 1.8rem;
  font-weight: 500;
  letter-spacing: 0.8px;
  background: linear-gradient(to right, #4db8ff, #9c42ff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 0 15px rgba(126, 87, 194, 0.4);
  margin: 0;
}

.workbench-controls {
  display: flex;
  align-items: center;
  gap: 1vw;
}

.analysis-dashboard {
  display: flex;
  flex: 1;
  gap: 1.5vw;
  height: calc(100% - 15vh);
}

.analysis-dashboard > * {
  flex: 1;
  background: rgba(16, 22, 46, 0.65);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(64, 140, 246, 0.25);
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(2, 8, 24, 0.4);
  overflow: hidden;
  position: relative;
  transition: all 0.3s ease;
}

.analysis-dashboard > *:hover {
  box-shadow: 0 8px 40px rgba(64, 140, 246, 0.3);
}

.workbench-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 1.5vh;
  padding-top: 1.5vh;
  border-top: 1px solid rgba(75, 130, 230, 0.3);
  font-size: 0.9rem;
}

.status-indicator {
  display: flex;
  align-items: center;
  gap: 0.5vw;
}

.status-indicator .el-icon {
  color: #2ecc71;
}

.status-active {
  color: #2ecc71;
  font-weight: 500;
}

.execution-info {
  color: #a0bff0;
}

.highlight {
  color: #4db8ff;
  font-weight: 500;
}
</style>